import axios from 'axios';
import {ADMIN} from './api';

var qs = require('qs');

export const login = (username, password) => {
  return axios.post(ADMIN + 'login', qs.stringify({
    user_name: username,
    pass_word: password
  }));
};

export const logout = () => {
  return axios.post(ADMIN + '/logout');
};

export const resetPwd = (param) => {
  return axios.post(ADMIN + '/reset_pwd', qs.stringify(param));
};
